package com.bookstore.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;

@Data
@TableName("review")
@ApiModel(description = "图书评论信息")
public class Review {
    @TableId(type = IdType.AUTO)
    @ApiModelProperty("评论ID")
    private Integer reviewId;

    @ApiModelProperty("用户ID")
    private Integer userId;

    @ApiModelProperty("图书ID")
    private Integer bookId;

    @ApiModelProperty("评分")
    private Integer rating;

    @ApiModelProperty("评论内容")
    private String content;

    @ApiModelProperty("评论图片")
    private String images;

    @ApiModelProperty("是否匿名")
    private Boolean anonymous;

    @ApiModelProperty("点赞数")
    private Integer likes;

    @ApiModelProperty("状态（0：待审核，1：已通过，2：已拒绝）")
    private Integer status;

    @ApiModelProperty("创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createdAt;

    @ApiModelProperty("更新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updatedAt;
} 